<?php
class ManagerController extends Zend_Controller_Action
{
    public function indexAction()
    {
        $this->view->headScript()->appendFile('/ckeditor/ckeditor.js');
    }

    public function submitAction()
    {
        $data  = $_POST;
        $blogM = new Application_Model_BlogMapper();
        $blog  = new Application_Model_Blog();
        $blog->title = $data["title"];
        $blog->content = $data["content"];
        $blog->keyword = explode(",", $data["keyword"]);
        $blogM->save($blog);
        $this->_redirect("/index/index");
    }
}
